3.1.51 \(\int e^{3 x} (-5 \cos (4 x)+2 \sin (4 x)) \, dx\) [51]

Optimal. Leaf size=27 \[ -\frac {23}{25} e^{3 x} \cos (4 x)-\frac {14}{25} e^{3 x} \sin (4 x) \]

[Out]

-23/25*exp(3*x)*cos(4*x)-14/25*exp(3*x)*sin(4*x)

________________________________________________________________________________________

Rubi [A]
time = 0.06, antiderivative size = 27, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.158, Rules used = {6874, 4518, 4517} \begin {gather*} -\frac {14}{25} e^{3 x} \sin (4 x)-\frac {23}{25} e^{3 x} \cos (4 x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[E^(3*x)*(-5*Cos[4*x] + 2*Sin[4*x]),x]

[Out]

(-23*E^(3*x)*Cos[4*x])/25 - (14*E^(3*x)*Sin[4*x])/25

Rule 4517

Int[(F_)^((c_.)*((a_.) + (b_.)*(x_)))*Sin[(d_.) + (e_.)*(x_)], x_Symbol] :> Simp[b*c*Log[F]*F^(c*(a + b*x))*(S
in[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x] - Simp[e*F^(c*(a + b*x))*(Cos[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x]
 /; FreeQ[{F, a, b, c, d, e}, x] && NeQ[e^2 + b^2*c^2*Log[F]^2, 0]

Rule 4518

Int[Cos[(d_.) + (e_.)*(x_)]*(F_)^((c_.)*((a_.) + (b_.)*(x_))), x_Symbol] :> Simp[b*c*Log[F]*F^(c*(a + b*x))*(C
os[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x] + Simp[e*F^(c*(a + b*x))*(Sin[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x]
 /; FreeQ[{F, a, b, c, d, e}, x] && NeQ[e^2 + b^2*c^2*Log[F]^2, 0]

Rule 6874

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps

\begin {align*} \int e^{3 x} (-5 \cos (4 x)+2 \sin (4 x)) \, dx &=\int \left (-5 e^{3 x} \cos (4 x)+2 e^{3 x} \sin (4 x)\right ) \, dx\\ &=2 \int e^{3 x} \sin (4 x) \, dx-5 \int e^{3 x} \cos (4 x) \, dx\\ &=-\frac {23}{25} e^{3 x} \cos (4 x)-\frac {14}{25} e^{3 x} \sin (4 x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.08, size = 22, normalized size = 0.81 \begin {gather*} -\frac {1}{25} e^{3 x} (23 \cos (4 x)+14 \sin (4 x)) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[E^(3*x)*(-5*Cos[4*x] + 2*Sin[4*x]),x]

[Out]

-1/25*(E^(3*x)*(23*Cos[4*x] + 14*Sin[4*x]))

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(102\) vs. \(2(21)=42\).
time = 0.10, size = 103, normalized size = 3.81

method result size
risch \(-\frac {23 \,{\mathrm e}^{\left (3+4 i\right ) x}}{50}+\frac {7 i {\mathrm e}^{\left (3+4 i\right ) x}}{25}-\frac {23 \,{\mathrm e}^{\left (3-4 i\right ) x}}{50}-\frac {7 i {\mathrm e}^{\left (3-4 i\right ) x}}{25}\) \(36\)
norman \(\frac {-\frac {28 \,{\mathrm e}^{3 x} \tan \left (2 x \right )}{25}+\frac {23 \,{\mathrm e}^{3 x} \left (\tan ^{2}\left (2 x \right )\right )}{25}-\frac {23 \,{\mathrm e}^{3 x}}{25}}{1+\tan ^{2}\left (2 x \right )}\) \(41\)
default \(-\frac {8 \left (3 \cos \left (x \right )+4 \sin \left (x \right )\right ) {\mathrm e}^{3 x} \left (\cos ^{3}\left (x \right )\right )}{5}+\frac {8 \left (3 \cos \left (x \right )+2 \sin \left (x \right )\right ) {\mathrm e}^{3 x} \cos \left (x \right )}{5}-\frac {3 \,{\mathrm e}^{3 x}}{5}-\frac {8 \,{\mathrm e}^{3 x} \cos \left (4 x \right )}{25}+\frac {6 \,{\mathrm e}^{3 x} \sin \left (4 x \right )}{25}-\frac {8 \,{\mathrm e}^{3 x} \cos \left (2 x \right )}{13}+\frac {12 \,{\mathrm e}^{3 x} \sin \left (2 x \right )}{13}-\frac {4 \,{\mathrm e}^{3 x} \left (3 \sin \left (2 x \right )-2 \cos \left (2 x \right )\right )}{13}\) \(103\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(3*x)*(-5*cos(4*x)+2*sin(4*x)),x,method=_RETURNVERBOSE)

[Out]

-8/5*(3*cos(x)+4*sin(x))*exp(3*x)*cos(x)^3+8/5*(3*cos(x)+2*sin(x))*exp(3*x)*cos(x)-3/5*exp(x)^3-8/25*exp(3*x)*
cos(4*x)+6/25*exp(3*x)*sin(4*x)-8/13*exp(3*x)*cos(2*x)+12/13*exp(3*x)*sin(2*x)-4/13*exp(3*x)*(3*sin(2*x)-2*cos
(2*x))

________________________________________________________________________________________

Maxima [A]
time = 0.27, size = 39, normalized size = 1.44 \begin {gather*} -\frac {2}{25} \, {\left (4 \, \cos \left (4 \, x\right ) - 3 \, \sin \left (4 \, x\right )\right )} e^{\left (3 \, x\right )} - \frac {1}{5} \, {\left (3 \, \cos \left (4 \, x\right ) + 4 \, \sin \left (4 \, x\right )\right )} e^{\left (3 \, x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(3*x)*(-5*cos(4*x)+2*sin(4*x)),x, algorithm="maxima")

[Out]

-2/25*(4*cos(4*x) - 3*sin(4*x))*e^(3*x) - 1/5*(3*cos(4*x) + 4*sin(4*x))*e^(3*x)

________________________________________________________________________________________

Fricas [A]
time = 1.19, size = 21, normalized size = 0.78 \begin {gather*} -\frac {23}{25} \, \cos \left (4 \, x\right ) e^{\left (3 \, x\right )} - \frac {14}{25} \, e^{\left (3 \, x\right )} \sin \left (4 \, x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(3*x)*(-5*cos(4*x)+2*sin(4*x)),x, algorithm="fricas")

[Out]

-23/25*cos(4*x)*e^(3*x) - 14/25*e^(3*x)*sin(4*x)

________________________________________________________________________________________

Sympy [A]
time = 0.10, size = 27, normalized size = 1.00 \begin {gather*} - \frac {14 e^{3 x} \sin {\left (4 x \right )}}{25} - \frac {23 e^{3 x} \cos {\left (4 x \right )}}{25} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(3*x)*(-5*cos(4*x)+2*sin(4*x)),x)

[Out]

-14*exp(3*x)*sin(4*x)/25 - 23*exp(3*x)*cos(4*x)/25

________________________________________________________________________________________

Giac [A]
time = 0.42, size = 39, normalized size = 1.44 \begin {gather*} -\frac {2}{25} \, {\left (4 \, \cos \left (4 \, x\right ) - 3 \, \sin \left (4 \, x\right )\right )} e^{\left (3 \, x\right )} - \frac {1}{5} \, {\left (3 \, \cos \left (4 \, x\right ) + 4 \, \sin \left (4 \, x\right )\right )} e^{\left (3 \, x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(3*x)*(-5*cos(4*x)+2*sin(4*x)),x, algorithm="giac")

[Out]

-2/25*(4*cos(4*x) - 3*sin(4*x))*e^(3*x) - 1/5*(3*cos(4*x) + 4*sin(4*x))*e^(3*x)

________________________________________________________________________________________

Mupad [B]
time = 0.06, size = 19, normalized size = 0.70 \begin {gather*} -\frac {{\mathrm {e}}^{3\,x}\,\left (23\,\cos \left (4\,x\right )+14\,\sin \left (4\,x\right )\right )}{25} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-exp(3*x)*(5*cos(4*x) - 2*sin(4*x)),x)

[Out]

-(exp(3*x)*(23*cos(4*x) + 14*sin(4*x)))/25

________________________________________________________________________________________